# -*- encoding=utf8 -*-
__author__ = "HiWin10"

from airtest.core.api import *
from airtest.cli.parser import cli_setup
from selenium import webdriver
if not cli_setup():
    auto_setup(__file__, logdir=True, devices=["android://127.0.0.1:5037/127.0.0.1:62001?cap_method=JAVACAP&ori_method=ADBORI&touch_method=ADBTOUCH&",])


# script content
print("start...")


# generate html reportdriver.find_element_by_xpath("使用F12查找元素并插入xPath. ").click()

# from airtest.report.report import simple_report
# simple_report(__file__, logpath=True)driver.get("http://127.0.0.1/dsmall/public/index.php/Admin/login/index.html")driver.find_element_by_name("admin_name")
driver = webdriver.Chrome()
driver.get("http://127.0.0.1/dsmall/public/index.php/Admin/login/index.html")
driver.find_element_by_name("admin_name").send_keys("admin")

driver.find_element_by_xpath("//input[@type='password']").send_keys("123456")
driver.find_element_by_name("captcha").send_keys("1111")
driver.find_element_by_xpath("//input[@type='submit']").click()















